load("@rules_apple//apple:macos.bzl", "macos_application")
load("@rules_cc//cc:defs.bzl", "objc_library")

objc_library(
    name = "macos_app_lib",
    srcs = glob([
        "*.h",
        "*.m",
    ]),
    enable_modules = True,
    deps = [
        "//platform:macos-objcpp",
    ],
)

macos_application(
    name = "macos_app",
    bundle_id = "org.maplibre.macosapp",
    infoplists = [
        "Info.plist",
    ],
    minimum_os_version = "11.0",
    resources = glob([
        "*.lproj/**",
        "Assets.xcassets/**",
    ]),
    visibility = [
        "@rules_xcodeproj//xcodeproj:generated",
    ],
    deps = [
        ":macos_app_lib",
    ],
)
